/*
 *  CCNodeContollerProxy.cpp
 *  cocos3d-x
 *
 *  Created by Yezhiyong on 12-4-23.
 *  Copyright 2012 __MyCompanyName__. All rights reserved.
 *
 */

#include "NodeControllerProxy.h"
#include "CCNodeController.h"

CCNodeControllerProxy::CCNodeControllerProxy()
{
}

CCNodeControllerProxy::~CCNodeControllerProxy()
{
}

cocos2d::CCNode* CCNodeControllerProxy::getControlledNode()
{
	return [[CCNodeController sharedController] controlledNode];
}

void CCNodeControllerProxy::setControlledNode(cocos2d::CCNode* aNode)
{
	return [[CCNodeController sharedController] setControlledNode:aNode];
}

void CCNodeControllerProxy::runSceneOnNode(cocos2d::CCNode* aNode)
{
	return [[CCNodeController sharedController] runSceneOnNode:aNode];
}

bool CCNodeControllerProxy::getIsOverlayingDeviceCamera()
{
	return [[CCNodeController sharedController] isOverlayingDeviceCamera];
}

CCNodeControllerProxy& CCNodeControllerProxy::sharedController()
{
	static CCNodeControllerProxy instance;
	return instance;
}

void CCNodeControllerProxy::destroyController()
{
	[[CCNodeController sharedController] destroyController];
}

void CCNodeControllerProxy::doesAutoRotate(bool bAutoRotate)
{
	[[CCNodeController sharedController] setDoesAutoRotate:bAutoRotate];
}

